import requests
from fake_useragent import UserAgent


'''
刷网站展示量
本代码仅供参考，点击代码正在制作中~_~
QQ：1065900200
keywords = 关键词
url      = 网址
rn       = 每页展示数量
'''
def brush_show(keywords,url,rn):
    ua = UserAgent()

    headers = {
        'User-Agent': ua.random,
    }

    url = "http://www.baidu.com/s?wd=%s&ie=utf-8&si=%s&ct=2097152&rn=%s" % (keywords,url,rn)
    try:
        requests.get(url,headers=headers,timeout=5)
        #更新数据
        print("成功了 :%s"%url)
    except:
        print("失败了")
        return False


if __name__ == "__main__":

    brush_show("python","www.runoob.com","10")
    

